package com.frxuexi.lib_base.db

import androidx.room.Dao
import androidx.room.Delete
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Query
import com.frxuexi.lib_base.entity.HourseDBBean

@Dao
interface HourseDao {

    @Insert(onConflict = OnConflictStrategy.REPLACE)
    fun addHourse(hourseDBBean: HourseDBBean):Long

    @Delete
    fun deleteHourse(hourseDBBean: HourseDBBean):Int

    @Query("select count(*) from hourse where id=:id")
    fun selectSC(id:Int):Int

    @Query("select * from hourse")
    fun selectHourse():List<HourseDBBean>
}

